package com.heima.wemedia.controller;

import com.alibaba.nacos.common.model.RestResult;
import com.heima.model.common.dtos.ResponseResult;
import com.heima.model.wemedia.entity.WmChannel;
import com.heima.wemedia.service.WmChannelService;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.PageRequest;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.*;

import javax.annotation.Resource;

/**
 * 自媒体频道表(WmChannel)表控制层
 *
 * @author makejava
 * @since 2022-04-12 15:59:27
 */
@RestController
@RequestMapping("/api/v1/channel")
public class WmChannelController {
    /**
     * 服务对象
     */
    @Resource
    private WmChannelService wmChannelService;

    /**
     * 查询频道列表
     */
    @GetMapping("/channels")
    public ResponseResult channels() {
        //查询所有
    return wmChannelService.queryAll();
    }

}

